<!DOCTYPE html>
<html>
	<head>
		<meta charset="utf-8">
		<meta name="viewport" content="initial-scale=1.0, maximum-scale=1.0, user-scalable=no" />
		<title></title>
		<link rel="stylesheet" href="../../css/font.css" />
		<link rel="stylesheet" href="../../css/common.css" />
		<link rel="stylesheet" href="../../css/team.css" />
		<script type="text/javascript">
			document.addEventListener('plusready', function() {
				//console.log("所有plus api都应该在此事件发生后调用，否则会出现plus is undefined。"

			});
		</script>

	</head>
	<body>
		<header class=" header-module ">
			<div class="flex-justify-align header-top">
				<a href="../../home.html" class="iconfont iconfanhuijiantou header-back"></a>
				<p class="header-title">政企通 - 专业团队</p>
				<span class="header-span"></span>
			</div>

		</header>
		<article class="middle-moudle">
			<section class="loans-data" id="loans-data">

			</section>
		</article>
		<footer class="footer-module">
			<nav class="flex-justify-align footer-nav ">
				<a href="../../home.html">
					<span class="iconfont iconshouye"></span>
					<p>首页</p>
				</a>
				<a href="../../apply.html">
					<span class="iconfont icontibao"></span>
					<p>提报</p>
				</a>
				<a href="../../setting.html">
					<span class="iconfont iconwode"></span>
					<p>我的</p>
				</a>
			</nav>
		</footer>
	</body>

	<script src="../../js/jquery-3.0.0.min.js"></script>
	<script src="../../js/gloab.js"></script>
	<script>
		$(function() {
			loadData();
		});
		
		function call(tel){
			window.location.href = 'tel://' + tel;
		}

		function loadData() {
			$.ajax({
				//请求方式    
				type: "GET",
				//文件位置    
				url: basePath + "app/tcompany/getVouchOrFundInfo",
				data: {
					"type": 2
				},
				//返回数据格式为json,也可以是其他格式如    
				dataType: "json",
				//请求成功拼接html    
				success: function(data) {
					console.log(data)
					var assureList = data.assureList;
					var str = "";
					$.each(assureList, function(i, n) {
						str += '<a class="flex-justify-align base-interval loans-item">';
						//str += '	<img src="../../img/loans/loans-data-type.png" />';
						str += '	<div class="loans-info">';
						str += '		<p>' + assureList[i].companyName + '</p>';
						str += '		<span style="text-indent: 2em;">' + assureList[i].companyContent + '</span>';
						if (assureList[i].contacter != null) {
							str += '		<span>联系人：' + assureList[i].contacter + '</span>';
						}
						if (assureList[i].telphone != null) {
							str += '<span>联系电话：' + assureList[i].telphone + '<img src="../../img/phone.jpg" style="width:3rem;margin-left: 0.7rem;padding: 0;" onclick="call('+assureList[i].telphone+')"/></span>';
						}
						str += '	</div>';
					
						str += '</a>';
					});
					$("#loans-data").append(str);
				}
			});
		}
	</script>
</html>
